package es.cea.biblioteca;

import java.io.IOException;
import java.io.PrintWriter;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * Servlet implementation class AplicacionInicio
 */
public class AplicacionInicio extends HttpServlet {
	private static final long serialVersionUID = 1L;
       
    public AplicacionInicio() {
    }

	protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		
		response.setContentType("text/html");
		PrintWriter writer = response.getWriter();
		
		writer.println("<html><head><title>Biblioteca - P&aacute;gina principal</title>"+
				"</head><body>"+
				"<h1>Biblioteca</h1>"+
				"<h2>&iquest;Qu&eacute; quieres hacer?</h2><br/>"+
				"<p><a href='./biblioteca'>Ver biblioteca general</a> || <a href='./usuarioLogin'>Login de usuario</a></p>");
		
	}

	protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		doGet(request, response);
	}

}
